from sqlalchemy import create_engine
from users import User
from admin_users import AdminUser
# from roles import Role
# from permissions import Permission
from admin_menus import AdminMenu
from sys_users import SysUser
from sys_roles import SysRole
from sys_user_roles import SysUserRole
from sys_depts import SysDept
from sys_role_depts import SysRoleDept
from sys_role_menus import SysRoleMenu
from sys_posts import SysPost
from sys_user_posts import SysUserPost
from base import Base  # 导入共享的 Base
import sys

sys.path.append("")
# from red_book.red_book_users import RedBookUser
# from red_book.red_book_vips import RedBookVIP
# from red_book.red_book_user_levels import RedBookUserLevel
from config.mysql_settings import DATABASE_URL
from pictures import Pictures
from files import Files
engine = create_engine(DATABASE_URL, echo=True)

# 创建或更新数据库表
Base.metadata.create_all(bind=engine)

print("Database tables created or updated successfully.")
